package com.kygeng.springframework.context.event;

import com.kygeng.springframework.context.ApplicationEvent;
import com.kygeng.springframework.context.ApplicationListener;

/**
 * @Title: ApplicationEventMulticaster
 * @Author: kygeng
 * @Package: com.kygeng.springframework.context.event
 * @Date: 2024/8/3 16:13
 * @Description: 事件广播器
 */
public interface ApplicationEventMulticaster {

    /**
     * 添加事件监听器
     */
    void addApplicationListener(ApplicationListener<?> listener);

    /**
     * 移除事件监听器
     */
    void removeApplicationListener(ApplicationListener<?> listener);

    /**
     * 广播事件
     */
    void multicastEvent(final ApplicationEvent event);


}
